"""
@Name:numpy-practice2.py
@Auth:YJ
@Date:2023/11/5
"""
import numpy as np
import pandas as pd

file_path = "./data/demo1.csv"
t1 = np.loadtxt(file_path, delimiter=",", dtype="int")
print(t1)
print("*" * 100)
# 取行
print(t1[0])
print("*" * 100)

# 取连续多行
print(t1[2:])
print("*" * 100)
# 取不连续多行
print(t1[[2, 5, 8]])
print("*" * 100)
# 取列
print(t1[:, [0, 2]])
